package com.tepth.busfix.main.repair;

import com.tepth.busfix.bean.reponse.BusRepairHistory;
import com.tepth.busfix.network.ApiModel;
import com.tepth.busfix.network.Network;

import java.util.List;

import io.reactivex.Observable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.schedulers.Schedulers;

/**
* Created by TMVPHelper on 2017/09/07
*/
public class HistoryModel implements HistoryContract.Model{

    @Override
    public Observable<ApiModel<List<BusRepairHistory>>> getRepairHistory(String authKey, String code) {
        return Network.getApiService().getRepairHistory(authKey, code)
                .subscribeOn(Schedulers.io())
                .observeOn(AndroidSchedulers.mainThread());
    }
}